import {get} from '@/utils/request/axios';

/**
 * 根据ID查询服务器基本信息和运行信息
 * @param id
 * @returns {*}
 */
export const getServerBaseInfoAndRunInfoById = (id) => {
  const url = "/leader/serversBaseInfo/getServerBaseInfoAndRunInfoById/"+id;
  return get(url);
};

/**
 * 查询最新N条cpu实时信息
 * @param id
 * @returns {*}
 */
export const listCpuTop = (id) => {
  const url = "/leader/serverCpuRealTime/listTop/"+id;
  return get(url);
};

/**
 * 查询最新N条Ram实时信息
 * @param id
 * @returns {*}
 */
export const listRamTop = (id) => {
  const url = "/leader/serverRamReaTime/listTop/"+id;
  return get(url);
};

/**
 * 获取硬盘使用信息情况
 * @param id
 * @returns {*}
 */
export const getDiskUseInfo = (id) => {
  const url = "/leader/serverDiskinfo/getDiskUseInfo/"+id;
  return get(url);
};
/**
 * 获取服务器磁盘信息列表
 * @param id
 * @returns {*}
 */
export const listDiskInfos = (id) => {
  const url = "/leader/serverDiskinfo/listDiskInfos/"+id;
  return get(url);
};
/**
 * 获取进程列表
 * @param id
 * @returns {*}
 */
export const listProcess = (id) => {
  const url = "/leader/serverProcessinfo/list/"+id;
  return get(url);
};
